﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using DevExpress.Skins;
using DevExpress.LookAndFeel;
using DevExpress.UserSkins;
using DevExpress.XtraBars.Helpers;
using DXWindowsApplication3.GUI;
using DXWindowsApplication3.DTO;


namespace DXWindowsApplication3
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
            InitSkinGallery();

        }
        void InitSkinGallery()
        {
            SkinHelper.InitSkinGallery(rgbiSkins, true);
        }


        private void iExit_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            Close();
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            iUsername.Caption = USER.UserName;//Goi Ten nguoi dang nhap
        }


        private void navQLLich_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            pctFrom.Controls.Clear();
            UCLichChieu u = new UCLichChieu();
            pctFrom.Controls.Add(u);
            u.Dock = DockStyle.Fill;
        }

        private void navQLRap_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            pctFrom.Controls.Clear();
            UCRap u = new UCRap();
            pctFrom.Controls.Add(u);
            u.Dock = DockStyle.Fill;
        }

        private void navQLPhong_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            pctFrom.Controls.Clear();
            UCPhong u = new UCPhong();
            pctFrom.Controls.Add(u);
            u.Dock = DockStyle.Fill;
        }

        private void navQLPhim_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            pctFrom.Controls.Clear();
            UCPhim u = new UCPhim   ();
            pctFrom.Controls.Add(u);
            u.Dock = DockStyle.Fill;
        }

        private void navQLVe_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            pctFrom.Controls.Clear();
            UCVe u = new UCVe();
            pctFrom.Controls.Add(u);
            u.Dock = DockStyle.Fill;
        }

        private void navQLNhanVien_LinkClicked(object sender, DevExpress.XtraNavBar.NavBarLinkEventArgs e)
        {
            pctFrom.Controls.Clear();
            UCNhanVien u = new UCNhanVien();
            pctFrom.Controls.Add(u);
            u.Dock = DockStyle.Fill;
        }

        private void Form1_Load_1(object sender, EventArgs e)
        {
            iUsername.Caption = "Chào "+USER.TenChucVu+": "+ USER.UserName;
        }


    }
}